#@adminLayout()
#define main()
<div class="card">
    #@cardAddOrEdit("数据字典管理 / "+(model?"修改":"新增"),"ciis/dictionary")
</div>
#end

###需要编辑的字段，默认展示了所有，需自己删除多余内容
#define cardCol()
    <input type="hidden" name="dictionary.id" value="#(model.id??)">
    <div class="col-sm-12">
        <div class="form-group">
            <lable>上级</lable>
            <select name="dictionary.pid" class="select2">
                <option value="0">请选择上级</option>
                #for(x:firstDictionaryList)
                <option value="#(x.id)" #(model.pid??==x.id?'selected':"")>#(x.name)</option>
                #end
            </select>
            <i class="form-group__bar"></i>
        </div>
    </div>
    <div class="col-sm-6">
        <div class="form-group">
            <lable>名称</lable>
            <input type="text" class="form-control" name="dictionary.name" value="#(model.name??)"
                   placeholder="请输入名称">
            <i class="form-group__bar"></i>
        </div>
    </div>
    <div class="col-sm-6">
        <div class="form-group">
            <lable>字段</lable>
            <input type="text" class="form-control" name="dictionary.field" value="#(model.field??)"
                   placeholder="请输入字段">
            <i class="form-group__bar"></i>
        </div>
    </div>
#end
<!--无用的可以删除-->
<script src="/assets/app/table.js?v=#(resource_version)"></script>